apiVersion: apps/v1
kind: Deployment
metadata:
  name: jupyter-notebook-server
  labels:
    app.kubernetes.io/name: jupyter-notebook-server
spec:
  replicas: 1
  selector:
    matchLabels:
      app.kubernetes.io/name: jupyter-notebook-server
  template:
    metadata:
      labels:
        app.kubernetes.io/name: jupyter-notebook-server
    spec:
      imagePullSecrets:
        - name:   nvcrio
      containers:
      - name: jupyter-notebook-server
        imagePullPolicy: IfNotPresent
        image: {{ .Values.jupyter.image }}
        ports:
        - containerPort: 8888
        resources:
          limits:
            {{ .Values.jupyter.gpu.type }}: {{ .Values.jupyter.gpu.count }} 
---
apiVersion: v1
kind: Service
metadata:
  name: jupyter-notebook-service
spec:
  type: NodePort

  selector:
    app.kubernetes.io/name: jupyter-notebook-server
  ports:
    - protocol: TCP
      port: 8888
      nodePort: 30000 